<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script type="text/javascript">
	this.imagePreview = function(){	
	xOffset = 10;
	yOffset = 30;
	$("a.preview").hover(function(e){
		this.t = this.title;
		this.title = "";	
		var c = (this.t != "") ? "<br/>" + this.t : "";
		$("body").append("<p id='preview'><img src='"+ this.href +"' alt='Image preview' width='200' height='150' />"+ c +"</p>");			
		$("#preview").css("top",(e.pageY - xOffset) + "px").css("left",(e.pageX + yOffset) + "px").fadeIn("fast");						
    	},
	function(){
		this.title = this.t;	
		$("#preview").remove();
    	});	
	$("a.preview").mousemove(function(e){
		$("#preview").css("top",(e.pageY - xOffset) + "px").css("left",(e.pageX + yOffset) + "px");
	});			
};
$(document).ready(function(){
	imagePreview();
});
</script>
<style>
#preview{
	position:absolute;
	border:1px solid #ccc;
	background:#333;
	padding:5px;
	display:none;
	color:#fff;
	}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Colony PCR Confirm B(700-For/700-Rev)</title>
</head>
<body>

<table width = "100%" bgcolor="#DBF3FF">
	<tr>
		<td width="70%">
			Colony PCR Confirm B
		</td>
		<td width="10%">
		 	<s:form action="GeneColonyHistory">
				<s:hidden value="%{geneName}" name="geneName" />
				<s:hidden value="B" name="type" />
				<s:submit value="history"/>
			</s:form>
		</td>
		<td width="10">
			<s:form action="emergencyReport" id="emergencyReportColonyB">
			<s:hidden value="%{geneName}" name="geneName" />
			<s:hidden value="Colony PCR Confirm B" name="formName"/>
			<input type="button" value="report" onclick="reportEmergencyColonyB()"/>
			</s:form>
		</td>
	</tr>
</table>
<center>
Genename:<s:property value="geneName"/>
</center>
<s:form action="updateGeneColony" id="updateGeneColonyB">
<table>
<s:if test='esize == 0'><tr><td><s:textfield label="Expected size (bp)" name="esize" value=""/></td></tr></s:if>
<s:else><tr><td><s:textfield label="Expected size (bp)" name="esize"/></td></tr></s:else>
</table>

<table width=100%>
	<tr>
	<td width="25%">
		<table>
			<tr>
				<td><s:textfield label="060-064 Date" name="date1"></s:textfield>
				</td>
			</tr>
		</table>
	</td>
	<td width="25%">
		<table>
			<tr>
				<td><s:textfield label="065-069 Date" name="date2"></s:textfield>
				</td>
			</tr>
		</table>
	</td>
	<td>
		<table>
			<tr>
				<td><s:textfield label="070-079 Date" name="date3"></s:textfield>
				</td>
			</tr>
		</table>
	</td>
	</tr>
</table>
<table width="100%">
<tr>
<td>
<table width="80%"  borderColor="#E0E0E0" border="0" style="BORDER-COLLAPSE: collapse">
	<tr><td><s:radio label="060" name="z60" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="061" name="z61" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="062" name="z62" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="063" name="z63" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="064" name="z64" list="{'yes','no'}" /></td></tr>
</table>
</td>
<td>
<table width="80%"  borderColor="#E0E0E0" border="0" style="BORDER-COLLAPSE: collapse">
	<tr><td><s:radio label="065" name="z65" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="066" name="z66" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="067" name="z67" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="068" name="z68" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="069" name="z69" list="{'yes','no'}" /></td></tr>
</table>
</td>
<td>
<table width="80%"  borderColor="#E0E0E0" border="0" style="BORDER-COLLAPSE: collapse">
	<tr><td><s:radio label="070" name="z70" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="071" name="z71" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="072" name="z72" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="073" name="z73" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="074" name="z74" list="{'yes','no'}" /></td></tr>
</table>
</td>
<td>
<table width="80%"  borderColor="#E0E0E0" border="0" style="BORDER-COLLAPSE: collapse">
	<tr><td><s:radio label="075" name="z75" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="076" name="z76" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="077" name="z77" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="078" name="z78" list="{'yes','no'}" /></td></tr>
	<tr><td><s:radio label="079" name="z79" list="{'yes','no'}" /></td></tr>
</table>
</td>

</tr>
</table>
<s:hidden name="geneName" value="%{geneName}"/>
<s:hidden name="type" value="B"/>
<center>
<table>
	<tr>
		<td align="center">
			<input type="button" value="update" onclick="updateColonyB()"/>
		</td>
	</tr>
</table>
</center>
</s:form>
<center>
	<p></p> 
	<table width="50%">
		<tr bgcolor="#DBF3FF">
		<td>Date Uploaded</td>
		<td>Uploader</td>
		<td>File Name</td>
		<td>Option</td>
		</tr> 
		<s:iterator value="imageList">
        <tr bgcolor="#E1EBED">
        	<td width="28%"><s:date name="dateModified" format="MM/dd/yyyy hh:mm:ss a"/></td>
        	<td width="15%"><s:property value = "user.userName"/></td>
        	<td><a href="<s:url action = "ViewImage"><s:param name = "id"><s:property value="id"/></s:param></s:url>"><s:property value= "fileName"/></a></td>
        	<td><a href="upload/<s:property value="fileName"/>" class="preview" >Preview</a>
        </tr>
        </s:iterator>       
   </table>   
<br>
</center>
</body>
</html>